export default {
  // 开启命名空间
  namespaced: true,

  // 数据
  state: () => ({
    courseinfo: uni.getStorageSync('courseinfo') || [],
   
  }),

  // 方法
  mutations: {
    updateCourseInfo(state, courseinfo) {
      state.courseinfo = courseinfo
      this.commit('m_course/saveCourseInfoToStorage')
    },
    saveCourseInfoToStorage(state) {
      uni.setStorageSync('courseinfo', state.courseinfo)
    },
    
  },
}
